package com.andnnl.event.dispatch;

import com.andnnl.event.events.ClickEvent;
import com.andnnl.event.events.DblClickEvent;
import com.andnnl.event.events.Event;

/**
 * Created by chenss on 2021/5/11.
 */
public class EventDispatcherTest {
    public static void main(String[] args) {
        EventManager manager = new EventManager();
        manager.init();
        manager.start();

        Event event=new ClickEvent();
        event.setEventType(EventType.CREATE);
        manager.notify(event);

        Event event2=new DblClickEvent();
        event2.setEventType(EventType.MODIFY);
        manager.notify(event2);
    }
}
